package com.atguigu.classes.preconditions;

import java.util.Scanner;

/**
 * @program: myIDEA
 * @description: 比较三个数的最大值
 * @author: Mr.zjx
 * create: 2021-07-04-22-40
 **/
public class Test08 {
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        System.out.println("请输入第一个数");
        int i = scanner.nextInt();
        System.out.println("请输入第二个数");
        int j = scanner.nextInt();
        System.out.println("请输入第三个数");
        int k = scanner.nextInt();
        int max = 0;
        if (i > j){
            max = i;
        }else {
            max = j;
        }
        if (k > max){
            max = k;
        }
        System.out.println("最大数是："+max);
    }
}
